package com.buymobile.controller;

import java.util.HashMap;
import java.util.List;
import java.util.Map;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.ui.Model;
import org.springframework.web.bind.annotation.RequestMapping;

import com.buymobile.service.CustomerService;
@Controller
@RequestMapping("/customer")
public class CustomerController {
	
	private CustomerService customerService;
	
	@Autowired
	public void setCustomerService(CustomerService customerService) {
		this.customerService = customerService;
	}




	@RequestMapping(value="findList")
	public String findList(Model model){
		
		Map map = new HashMap();
		int count = customerService.findCount(map);
		List list = customerService.findList(map);
		model.addAttribute("list", list);
		return "/manager/customer/list";
	}
}
